package com.satalyst.webtest.model;

import com.satalyst.webtest.model.page.PageGroup;
import com.satalyst.webtest.model.test.design.TestGroup;

import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
import java.util.UUID;

/**
 * @author Aidan Morgan
 */
public class Project {
    private UUID id;
    private String name;

    private List<PageGroup> pages;
    private List<TestGroup> tests;

    public Project() {
        this(UUID.randomUUID(), "Unnamed Project");
    }

    public Project(UUID id, String name) {
        this.id = id;
        this.name = name;

        this.pages = new ArrayList<PageGroup>();
        this.tests = new ArrayList<TestGroup>();
    }

    public UUID getId() {
        return id;
    }

    public void setId(UUID id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public List<PageGroup> getPages() {
        return Collections.unmodifiableList(pages);
    }

    public List<TestGroup> getTests() {
        return Collections.unmodifiableList(tests);
    }
}
